<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <title><@spring.message "登录" /></title>
<#include "/admin/main/include/link_head.ftl"/>
</head>

<body class="login-body" style="visibility: visible;">

<div class="container">

    <form class="form-signin" action="<@spring.url '/admin/login' />" method="post">
        <div class="form-signin-heading text-center">
            <h1 class="sign-title">Sign In</h1>
            <img src="<@spring.url '/admin/resources/plugins/${lang}/adminex/images/login-logo.png' />" alt=""/>
        </div>
        <div class="login-wrap">
            <input type="text" name="usern" value="dev" class="form-control" placeholder="用户名" autofocus/>
            <input type="password" name="password" value="jereh123" class="form-control" placeholder="密码"/>
            <#if showAuthCode??&&showAuthCode>
                <div>
                    <input style="width:200px;float: left;" type="text" name="authCode" value="" class="form-control"
                           placeholder="验证码"/>
                    <img id="authCode" style="float: left;margin: 1px 0 0 5px;width: 80px;height: 35px;cursor: pointer;"
                         src="<@spring.url '/admin/authCode' />"/>
                </div>
            </#if>

            <button class="btn btn-lg btn-login btn-block" type="submit">
                <i class="fa fa-check"></i>
            </button>
            <label class="checkbox">
                <span class="pull-right">
                    <input type="checkbox" name="rememberMe" value="true"/> Remember me
                </span>
            </label>
        ${message}
        </div>

    </form>

</div>
</body>
</html>
<!-- Placed js at the end of the document so the pages load faster -->
<script src="<@spring.url '/admin/resources/plugins/${lang}/adminex/js/jquery-1.10.2.min.js' />"></script>
<script src="<@spring.url '/admin/resources/plugins/${lang}/adminex/js/bootstrap.min.js' />"></script>
<script src="<@spring.url '/admin/resources/plugins/${lang}/adminex/js/modernizr.min.js' />"></script>
<script type="text/javascript">
    $(function () {
        $("#authCode").click(function () {
            $("#authCode").attr("src", "<@spring.url '/admin/authCode' />?d=" + new Date());
        });
    });
</script>